<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <title>v-model sample</title>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
</head>

<body>

    <div id="sample-1">
        <div>

            <input v-model="message" placeholder="edit me">
            <p>Message is: {{ message }}</p>
        </div>
        <div>
            <span>Multiline message is:</span>
            <p style="white-space: pre-line;">{{ mulmsg }}</p>
            <br>
            <textarea v-model="mulmsg" placeholder="add multiple lines"></textarea>
        </div>
    </div>

    <div id='example-3'>
        <input type="checkbox" id="jack" value="Jack" v-model="checkedNames">
        <label for="jack">Jack</label>
        <input type="checkbox" id="john" value="John" v-model="checkedNames">
        <label for="john">John</label>
        <input type="checkbox" id="mike" value="Mike" v-model="checkedNames">
        <label for="mike">Mike</label>
        <br>
        <span>Checked names: {{ checkedNames }}</span>
    </div>


    <div id="example-4">
        <input type="radio" id="one" value="One" v-model="picked">
        <label for="one">One</label>
        <br>
        <input type="radio" id="two" value="Two" v-model="picked">
        <label for="two">Two</label>
        <br>
        <span>Picked: {{ picked }}</span>
    </div>


</body>

<script>

    var app1= new Vue({
        el: '#example-4',
        data: {
            picked: ''
        }
    })

    new Vue({
        el: '#example-3',
        data: {
            checkedNames: []
        }
    })


    var app = new Vue({
        el: "#sample-1",
        data: {
            message: "message",
            mulmsg: "Multiline"
        }
    })
</script>

</html>